package com.mioto.ld.module.statistics.model;

import com.mioto.ld.utils.BaseUtil;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
 * @author mioto-qinxj
 * @date 2024/6/16
 * @desc
 */
@Getter
@Setter
@ApiModel("统计搜索条件")
public class SearchConditionDTO {

    @ApiModelProperty("搜索类型 1-周 2-月 3-年 4-自定义时间段")
    private int searchType;
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("开始日期 搜索类型为4时传")
    private Date startTime;
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("结束日期 搜索类型为4时传")
    private Date endTime;

    @ApiModelProperty(value = "同期开始日期",hidden = true)
    protected Date sameCompareStartDate;

    @ApiModelProperty(value = "同期结束日期",hidden = true)
    protected Date sameCompareEndDate;

    @ApiModelProperty(value = "用于筛选数据权限",hidden = true)
    private Integer userId = BaseUtil.buildUserFilterCondition();
}
